home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Almathera Ten Pack 3: CDPD 3
/
Almathera Ten on Ten - Disc 3: CDPD3.iso
/
fish
/
001-100
/
001-025
/
009
/
mvp-forth
/
mvpamiga.ext
< prev
next >
Wrap
Text File
|
1995-03-17
|
5KB
|
1 lines
\ Special Amiga extensions load screen gst851224 2 4 thru \ load special extensions \ ON OFF ASCII gst851224 : ON \ addr -- | set to TRUE true swap ! ; : OFF \ addr -- | set to FALSE false swap ! ; : ASCII \ -- n | state smart converts char to numeric bl word 1+ c@ [compile] literal ; immediate \ "Register Stuffing" gst850930: Get.Reg# ( -- <digit> regaddr \ parses out a digit ) bl word dup count >Uppercase 1+ c@ 10 digit 0= abort" Huh?" 4 * Registers + ; : Tagged? ( c -- f ) here 2+ c@ = here c@ 1 > and ; : WhichReg ( -- regaddr ) Get.Reg# ascii W tagged? ascii B tagged? or if compile LITW! else ascii L tagged? if compile LIT! 2+ else ascii X tagged? if compile LITX! else ascii H tagged? if compile LIT! else compile LIT2! then then then then ; \ W or B pads 0 in high, L and H stuff half the reg \ X forces sign extension \ Exec interface -- lib calling gst850930: >RD WhichReg , ( offset) ; immediate : >RA WhichReg 32 + , ( offset to A regs) ; immediate : LVO, ( -- <hexnum> hexnum ) base @ >R [compile] hex bl word dup count >Uppercase number drop r> base ! , ; : EXEC: ( -- <LVO> \ compile an EXEC call ) compile LIBRARY: ExecBase , LVO, ; immediate : DOS: ( -- <LVO> \ compile a DOS call ) compile LIBRARY: DosBase , LVO, ; immediate \ used: : FOO ... >RA 1 >RD 0W DOS: FFE0 RESULT ... ;